5a6 > Node prev; 20c21,23 < tail = head; --- > tail = new Node(); > head.next = tail; > tail.prev = head; 29,30c32,35 < tail.next = tmp; < tail = tmp; --- > tmp.prev = tail.prev; > tmp.next = tail; > tail.prev.next = tmp; > tail.prev = tmp; 36c41 < for (Node n = head.next; n != null; n = n.next) --- > for (Node n = head.next; n != tail; n = n.next) 41,46d45 < private Node findPrev(Object x) { < for (Node p = head; p.next != null; p = p.next) < if (p.next.item.equals(x)) < return p; < return null; < } 50,51c49,50 < Node p = findPrev(x); < p.next = n.next; --- > n.next.prev = n.prev; > n.prev.next = n.next; 53,54c52 < if (n == tail) < tail = p; --- > n.prev = null; 66c64 < for (Node n = head.next; n != null; n = n.next) --- > for (Node n = head.next; n != tail; n = n.next) 72c70 < for (Node n = head.next; n != null; n = n.next) { --- > for (Node n = head.next; n != tail; n = n.next) { 74c72 < if (n.next != null) --- > if (n.next != tail) 106c104 < return current != null; --- > return current != tail;